package com.steam.job;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import com.steam.service.JedisClient;
@Component
public class JishuSpringJob {
	@Autowired
	private JedisClient jedisClient;
	/**
	 * 从早上七点到晚上8点之间每隔2秒时间来扫描数据库的信息
	 */
	@Scheduled(cron = "0 0 2 * * ? ")
	public void jining() {
//		jedisClient.del("jining");//凌晨2点清除济宁的基数数据
//		jedisClient.del("lianyungang");//凌晨2点清除连云港的基数数据
//		jedisClient.del("weihai");//凌晨2点清除威海的基数数据
//		jedisClient.del("linyi");//凌晨2点清除临沂的基数数据
		
		jedisClient.set("ljinan", "0");
		jedisClient.set("ljining", "0");
		jedisClient.set("lweifang", "0");
		jedisClient.set("lweihai", "0");
		jedisClient.set("ltaian", "0");
	}
}